package com.VancouverTongue.bean;

import com.VancouverTongue.database.HelpObj;

public class Rating {

	private int rateId;
	private String userId;
	private int restaurantId;
	private int rating;

	public Rating() {

		rateId = 0;
		userId = "";
		rating = 0;
		restaurantId = 0;

	}

	public int getRateId() {
		return rateId;
	}

	public void setRateId(int rateId) {
		this.rateId = rateId;
	}

	public String getUserId() {
		return userId;
	}

	public void setUserId(String userId) {
		this.userId = HelpObj.HTMLcheck(userId);
		this.userId = HelpObj.checkString(this.userId, 15);
	}

	public int getRestaurantId() {
		return restaurantId;
	}

	public void setRestaurantId(int restaurantId) {
		this.restaurantId = restaurantId;
	}

	public int getRating() {
		return rating;
	}

	public void setRating(int rating) {
		this.rating = rating;
	}

	public void addRating(int rateid, String userid, int rating,
			int restaurantid) {
		this.rateId = rateid;
		this.userId = HelpObj.HTMLcheck(userid);
		this.userId = HelpObj.checkString(this.userId, 15);
		this.rating = rating;
		this.restaurantId = restaurantid;
	}

}
